<!DOCTYPE html>
<html lang="zh-cn">
    <head>
        <meta charset="UTF-8"/>
        <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
        <title>Document</title>
    </head>
    <body>
        <img class="lazyload" src="img/56x56.png" data-src="img/big.jpg" />
        <script src="js/lazyload.js"></script>
        <script>
            // window.addEventListener("load", function(event) {
            //     lazyload();
            // });
            let lazy = lazyload();
            // lazy->loadImages();// 加载所有图片
            // lazy->destroy();//销毁lazyload实例
            // lazy->loadAndDestroy();//加载视图内的图片，完成后销毁lazyload实例
            lazy.loadImages();
        </script>
    </body>
</html>